package SingletonPattern;

/**
 * @Author: zhaojie
 * @Date: Created in 10:57 2018/6/26
 * @Description: 登记式/静态内部类
 */
public class SingleLogin {

    private static class SingletonHolder{
        private static final SingleLogin SINGLE_LOGIN=new SingleLogin();
    }

    private SingleLogin(){}

    public static final SingleLogin getInstance(){
        return SingletonHolder.SINGLE_LOGIN;
    }
}
